<?php

/**
 * Homepage Portfolio Item
 *
 * @param URL    $link  Link to the full article
 * @param URL    $image location of the thumb image
 * @param string $title Title of the article
 * @param string $tags  Tags to describe the work
 * @param string $class Custom class to append to .portfolio__
 */

?>

<figure class="portfolio__<?= $class ?: 'unknown' ?>">
    <a href="<?= url($link ?: '') ?>">
        <img src="<?= $image ?: 'http://placehold.it/320x320' ?>" alt="<?= $title ?: 'Untitled' ?>" width="320" height="180">
    </a>
    <figcaption>
        <p class="portfolio__item-title"><a href="<?= url($link ?: '') ?>"><?= $title ?: 'Untitled' ?></a></p>
        <p class="portfolio__item-terms"><?= $tags ?: 'no tags' ?></p>
    </figcaption>
</figure>
